package vn.orderonline.core.redis.model;

public class RedisConfiguration {

	private String readHost;
	
	private Integer readPort;
	
	private String writeHost;
	
	private Integer writePort;
	
	private Integer maxConnection;
	
	private Integer databaseIndex;

	public RedisConfiguration() {

	}

	public RedisConfiguration(String readHost, Integer readPort,
			String writeHost, Integer writePort, Integer maxConnection,
			Integer databaseIndex) {
		this.readHost = readHost;
		this.readPort = readPort;
		this.writeHost = writeHost;
		this.writePort = writePort;
		this.maxConnection = maxConnection;
		this.databaseIndex = databaseIndex;
	}

	public String getReadHost() {
		return readHost;
	}

	public void setReadHost(String readHost) {
		this.readHost = readHost;
	}

	public Integer getReadPort() {
		return readPort;
	}

	public void setReadPort(Integer readPort) {
		this.readPort = readPort;
	}

	public String getWriteHost() {
		return writeHost;
	}

	public void setWriteHost(String writeHost) {
		this.writeHost = writeHost;
	}

	public Integer getWritePort() {
		return writePort;
	}

	public void setWritePort(Integer writePort) {
		this.writePort = writePort;
	}

	public Integer getMaxConnection() {
		return maxConnection;
	}

	public void setMaxConnection(Integer maxConnection) {
		this.maxConnection = maxConnection;
	}

	public Integer getDatabaseIndex() {
		return databaseIndex;
	}

	public void setDatabaseIndex(Integer databaseIndex) {
		this.databaseIndex = databaseIndex;
	}

	@Override
	public String toString() {
		StringBuilder builder = new StringBuilder();
		builder.append("RedisConfiguration [readHost=");
		builder.append(readHost);
		builder.append(", readPort=");
		builder.append(readPort);
		builder.append(", writeHost=");
		builder.append(writeHost);
		builder.append(", writePort=");
		builder.append(writePort);
		builder.append(", maxConnection=");
		builder.append(maxConnection);
		builder.append(", databaseIndex=");
		builder.append(databaseIndex);
		builder.append("]");
		return builder.toString();
	}
}
